package org.aeon.dao;


import org.aeon.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * 用户
 *
 * @author MissingAeon
 * @email nian0950@qq.com
 * @date 2024-01-25 17:39:34
 */
public interface UserDao {

    User getById(@Param("id") Long id);

    List<User> getByIds(@Param("ids") List<Long> ids);

    List<User> getAll();

    User login(@Param("username") String username, @Param("password") String password);

    Long getIdByUsername(@Param("username") String username);

    int insert(@Param("user") User user);

    int updateUserTime(@Param("userId") Long userId, @Param("date") Date date);

    int isExist(@Param("userId") Long userId);

    List<Long> getAllId();
    // int updateUser(@Param("user") User user);
}
